package com.luyuan.gallery.vo;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;

/**
 * 两级评论VO
 * 
 * @author luyuan
 * @date 2025-11-10
 */
public class HierarchicalCommentVO implements Serializable {
    private static final long serialVersionUID = 1L;

    /** 主键ID */
    private Long id;

    /** 评论目标id */
    private String targetId;

    /** 评论人id */
    private Long userId;

    /** 评论人昵称 */
    private String nickName;

    /** 评论人头像 */
    private String avatar;

    /** 根评论id */
    private Long rootId;

    /** 所属评论id，主评论为null */
    private Long parentId;

    /** 评论内容 */
    private String content;

    /** 点赞数量 */
    private Long likeCount;

    /** 当前用户是否点赞 */
    private Boolean isLiked;

    /** 状态 */
    private Integer status;

    /** 创建时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    /** 子评论列表 */
    private List<HierarchicalCommentVO> replies;

    public void setId(Long id) {
        this.id = id;
    }

    public Long getId() {
        return id;
    }

    public void setTargetId(String targetId) {
        this.targetId = targetId;
    }

    public String getTargetId() {
        return targetId;
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public String getNickName() {
        return nickName;
    }

    public void setNickName(String nickName) {
        this.nickName = nickName;
    }

    public String getAvatar() {
        return avatar;
    }

    public void setAvatar(String avatar) {
        this.avatar = avatar;
    }

    public void setRootId(Long rootId) {
        this.rootId = rootId;
    }

    public Long getRootId() {
        return rootId;
    }

    public void setParentId(Long parentId) {
        this.parentId = parentId;
    }

    public Long getParentId() {
        return parentId;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getContent() {
        return content;
    }

    public void setLikeCount(Long likeCount) {
        this.likeCount = likeCount;
    }

    public Long getLikeCount() {
        return likeCount;
    }

    public void setIsLiked(Boolean isLiked) {
        this.isLiked = isLiked;
    }

    public Boolean getIsLiked() {
        return isLiked;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Integer getStatus() {
        return status;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public List<HierarchicalCommentVO> getReplies() {
        return replies;
    }

    public void setReplies(List<HierarchicalCommentVO> replies) {
        this.replies = replies;
    }

}